from collections.abc import Awaitable, Callable
from typing import overload

@overload
def _to_js[T](value: Awaitable[T]) -> Awaitable[T]: ...
@overload
def _to_js[T](value: T) -> T: ...
@overload
def js_api[**P, T](func: Callable[P, Awaitable[T]]) -> Callable[P, Awaitable[T]]: ...
@overload
def js_api[**P, T](func: Callable[P, T]) -> Callable[P, T]: ...
